home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Business Assistant
/
Business Assistant.iso
/
home
/
hb20d1
/
inshard.bat
< prev
next >
Wrap
DOS Batch File
|
1986-06-19
|
8KB
|
313 lines
rem INSHARD.BAT June 19,86 (%1=drivelet:,%2=yes/no,%3=f/h,%4+%5=d:s)
%1
cd \
cls
echo
HomeBase HARD DISK Installation
echo -------------------------------
echo (HomeBase needs about 510 Kbytes of available disk space
echo for the \homebase directory and an additional 181 K if swap
echo is specified. The current autoexec.bat and config.sys
echo should be on %1\, i.e. the root directory, if they are to
echo be modified for auto-bootup. For additional (optional)
echo syntax type: a:install help.)
if %2/ == yes/ goto yes9
a:ask Is your hard (or 720k+ floppy) disk drive letter %1
if errorlevel 2 echo
RE-RUN this install with correct drive letter (e.g. install D:)
if errorlevel 2 a:insquit xxx
:yes9
cls
echo
Checking disk free space
echo * Please Wait...
a:diskfree %1homebase
if not errorlevel 3 goto nuf1
echo
*ERROR* Disk %1 does not have enough empty space for HomeBase to fit.
echo Please free up 510 Kilobytes of space and rerun this install program.
a:insquit xxx
:nuf1
rem if not errorlevel 2 goto nuf2
if errorlevel 2 echo You have very little memory left on your hard disk drive %1.
if errorlevel 2 echo Watch for "INSUFFICIENT DISK SPACE" errors on the screen.
rem :nuf2
if not errorlevel 1 echo
* Please Wait...
if not errorlevel 1 goto nuf3
echo You already have a \HOMEBASE directory so this is probably
echo an UPDATE to a new version. The old version of HomeBase
echo will be erased and the new version put in its place.
echo Data files like NAMEADDR.NBD, etc. will not be erased, but if
echo you already have unconverted (Ver 1.04) .NBD or .NBR files
echo you MUST convert them to the new format using HBNBFIX
echo (supplied on Disk 1).
if %2/ == yes/ goto yes15
a:ask Ok to erase the old version of HomeBase and proceed
if errorlevel 2 a:insquit
cls
echo
Your config.sys file and autoexec file must NOT have references
echo to HomeBase put there from a previous install of HomeBase
echo e.g. "device=hbkernel.bin" or "hbkernel", etc.
cd \homebase
if exist autoexec.old goto nuf2
cd \
a:ask Are your CONFIG.SYS and AUTOEXEC.BAT free of HomeBase references
if not errorlevel 2 goto nuf3
cd \homebase
if not exist %1autoexec.old a:insquit
:nuf2
echo
HomeBase saved your original AUTOEXEC.BAT as AUTOEXEC.OLD. With your
echo permission the .OLD file will be used to form the new autoexec.bat.
echo The current autoexec.bat will be renamed autoexec.hbo.
a:ask OK to use AUTOEXEC.OLD
if errorlevel 2 a:insquit
:yes15
if exist %1autoexec.bat copy %1autoexec.bat %1\homebase\autoexec.hbo
cd \homebase
if exist %1autoexec.old copy %1autoexec.old %1\autoexec.bat
cd \
:nuf3
cls
rem is this necess anymore???
echo
Adding %1\HOMEBASE; to PATH if necessary
echo * Please wait...
a:gpath > %1\n_w$path.t$p
if not errorlevel 1 goto insthb1
a:gpath %1\homebase; > %1\n_w$path.t$p
:insthb1
if %2/ == yes/ goto yes19
cls
echo
If this install procedure fails, you may not be able to boot
echo up off of the hard disk until you restore the autoexec.bat file
echo which is modified during installation. For safety, you need
echo a floppy Boot disk that will allow you to reboot.
a:ask Do you have a floppy DOS Boot (System) disk
if errorlevel 2 a:insquit
cls
echo
Installation of HomeBase will change your AUTOEXEC.BAT file. For
echo safety, the original autoexec.bat file is changed to AUTOEXEC.OLD.
echo If this installation fails, you will have to restore this file to
echo its original name by typing:
echo copy %1\autoexec.old \autoexec.bat
echo This information is also in your HomeBase Installation document.
a:ask Are you willing to take this risk of temporary failure
if errorlevel 2 a:insquit
:yes19
rem done this way since stupid dos accumulates handles
echo %4 %5 > %1\hbconfig.hb$
if %4/==/ del %1\hbconfig.hb$
if %4/==./ del %1\hbconfig.hb$
rem if swap specd (in %4 and %5) skip questions
if not %4/==/ goto yes20
rem yes here means use old hbconfig file -- no change
if %2/ == yes/ goto yes21
echo -s >%1\hbconfig.hb$
cls
echo
HomeBase Ver 2.0 supports "swapping" so that 134K of RAM (memory) is
echo given up for use by your other programs (e.g. word processor, etc.).
echo However, swapping takes time and will slow down your exits and
echo entries into HomeBase. (Once within HomeBase speed is not
echo hampered.) Hard disks take 3-5 seconds, RAM disks take 1 sec.
a:ask Do you want HomeBase to swap
if errorlevel 2 goto yes20
cls
echo
Swapping utilizes a special "swap" file on your disk that needs
echo 180 K of available (free) space. It is best (fastest) to place
echo the swap file on a RAM disk which uses the special "above" or
echo "extended" memory. (Use the VDISK program supplied with DOS.)
echo If you have a RAM disk (or alternate disk) specify the drive
echo letter like E: (You MUST type the ":"). If it is drive %1
echo you may just press [Enter].
a:ask ..Enter the swap file disk drive letter (like E:) >%1\hbconfig.hb$
echo s >>%1\hbconfig.hb$
:yes20
if %2/ == yes/ goto yes21
cls
echo
-- ANSWER CAREFULLY --
echo A "yes" answer here will start installation of HomeBase.
a:ask Ok to install HOMEBASE
if errorlevel 2 a:insquit
:yes21
%1
cd \
a:diskfree %1homebase create ;creates and sets \homebase if enuf space avail
cls
echo
* * * Installing HomeBase * * * (please wait)
cd \homebase
if exist hbconfig.hb$ copy hbconfig.hb$ hbconfig.hbb
if %4/==./ goto ihb35
if exist hbconfig.hb$ del hbconfig.hb$
:ihb35
if exist autoexec.hbo copy autoexec.hbo \autoexec.hbo
if exist autoexec.old del autoexec.old
cd \
if exist autoexec.bat copy autoexec.bat \homebase\autoexec.old
echo files=20 >con$fig.$h$
if exist config.sys copy config.sys con$fig.$h$
a:files20 < con$fig.$h$ >config.sys
del con$fig.$h$
if exist hbconfig.hb$ copy hbconfig.hb$ \homebase\hbconfig.hb$
if exist hbconfig.hb$ del hbconfig.hb$
cd \homebase
if exist autoexec.old copy autoexec.old \autoexec.old
if exist hbkernel.bin del hbkernel.bin
if exist hbasync.bin del hbasync.bin
if exist hbvsi.exe del hbvsi.exe
copy \n_w$path.t$p+a:\autohard.bat h$$h$$ba.ba$ >nul
echo %1 > homebase.bat
a:ifasync < h$$h$$ba.ba$ >> homebase.bat
copy autoexec.old+homebase.bat \autoexec.bat >nul
copy homebase.bat \homebase.bat >nul
copy a:\insdone.bat+\n_w$path.t$p insdone.bat >nul
del h$$h$$ba.ba$
del \n_w$path.t$p
copy a:hb*.*
cls
:insthb3
echo
Please place HomeBase DISK 2 in drive A:
pause
if not exist a:disk2.doc echo
ERROR * WRONG DISK but do not change it yet -- Wait...
if not exist a:disk2.doc goto insthb3
copy a:hb*.*
copy a:swap.com
if %2/ == yes/ goto yes30
if exist *.nb* cls
if exist *.nb* echo
REMEMBER to run HBNBFIX to convert any Ver. 1.04 NBD and NBR files
if exist *.nb* pause
:yes30
if not exist nameaddr.nbd copy a:nameaddr.nbd
if not exist messages.nbd copy a:messages.nbd
if not exist areacode.nbd copy a:areacode.nbd
if not exist labels.nbr copy a:labels.nbr
if not exist roladex.nbr copy a:roladex.nbr
if not exist nameaddr.nbr copy a:nameaddr.nbr
if not exist proginfo.nbd copy a:proginfo.nbd
cls
echo
Installation of HomeBase has:
echo 1) Put "files=20" into a CONFIG.SYS file.
echo 2) Created or modified the AUTOEXEC.BAT file (if any).
echo Several lines relating to HomeBase have been placed at
echo the very end. However, if your original AUTOEXEC.BAT called
echo another BAT file to complete the boot-up process, you must fix
echo this by placing the call to the other BAT file at the end,
echo after the HomeBase lines. PLEASE! Do this before re-booting.
if not %2/ == yes/ pause
insdone ddd %1